package com.tedu.egmvc2.controller;

import com.tedu.egmvc2.pojo.dto.EmpDTO;
import com.tedu.egmvc2.pojo.entity.Emp;
import com.tedu.egmvc2.pojo.vo.EmpVO;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;


@Controller
public class EmpController {
    @RequestMapping("/emp/add")
    @ResponseBody
    public String insert(EmpDTO empDTO){
        System.out.println(empDTO.toString());
        return "添加成功";
    }
    @RequestMapping("/emp/list")
    @ResponseBody
    public String select(){
        return "查询成功";
    }
    @RequestMapping("/emp/update")
    @ResponseBody
    public String update(Emp emp){
        System.out.println(emp.toString());
        return "修改成功";
    }
    @RequestMapping("/emp/delete")
    @ResponseBody
    public String delete(Integer id){
        return "删除成功";
    }
}
